package com.lsb.service;

import com.lsb.pojo.Submit;
import com.baomidou.mybatisplus.extension.service.IService;
import com.lsb.pojo.User;
import com.lsb.vo.SubmitVO;
import org.springframework.scheduling.annotation.Scheduled;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.Date;
import java.util.LinkedHashMap;
import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author liusibo
 * @since 2021-06-10
 */
public interface SubmitService extends IService<Submit> {
    //定时任务，每天定时插入所有用户第二天的打卡记录，is_submit字段默认为0表示用户还未提交
    void insertData();
    //拿到今日的健康打卡数据
    void getTodaySubmit(HttpServletResponse response) throws IOException, ServletException;
    //拿到所有的打卡数据
    void getAllSubmit(HttpServletResponse response) throws IOException, ServletException;
    //异常体温筛选
    void getAbnormalTemperature(List<SubmitVO> submitList, HttpServletResponse response)throws Exception;
    //未提交筛选
    void getUncommitted(List<SubmitVO> submitList, HttpServletResponse response)throws Exception;
    //根据日期筛选打卡数据
    void getDateSubmit(String date, HttpServletResponse response)throws Exception;
    //根据学号模糊查询
    void getSubmitByUsernameMohu(List<LinkedHashMap> submitVOList, String username, HttpServletResponse response)throws Exception;
    //拿到当日打卡的图表数据
    void getTodayChart(HttpServletResponse response)throws Exception;
    //插入注册用户当天的打卡记录或当天和明天的打卡记录
    void insertRegisterSubmit(User user, int flag);
}
